<template>
  <div >
    <div class="search-goback">
      <div class="search-goback__icon" @click="goBack()">🔙</div>
    </div>
    <search-result-tab v-for="item in searchResItems" :key="item.id" :data-item="item" :highlight="highlightSearchContent" @openPage="openPageHandle($event)"></search-result-tab>
  </div>
</template>
<script>
import SearchResultTab from '@/components/Search/SearchItemTab.vue'
export default {
  components: {
    SearchResultTab
  },
  props: {
    searchResItems: {
      type: Array,
      default: () => []
    }
  },
  data() {
    return {
      highlightSearchContent: true
    }
  },
  methods: {
    goBack() {
      this.$emit('goBack');
    },
    openPageHandle(param){
      this.$emit('openPage', param);
    }
  }
}
</script>
<style scoped>

.search-goback{
  position: relative;
  text-align: left;
  font-size: 16px;
  padding:5px 0px 10px;
}
</style>